-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Preconditioner and Factorization config #1479
Conversation
0b19c10
to
91840c1
Compare
797e80d
to
70c9452
Compare
91840c1
to
03cc9db
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs 38.7% Coverage The version of Java (11.0.3) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 17. |
03cc9db
to
906e8b5
Compare
4933ac5
to
2d5fed4
Compare
b598f26
to
367d615
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm. The same comment on array parameters as in #1480 apply. I would also suggest a uniform error message if an unsupported string value is provided.
core/config/config_helper.hpp
Outdated
* specialize for const LinOpFactory | ||
*/ | ||
template <typename T> | ||
inline deferred_factory_parameter<typename T::Factory> get_specific_factory( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this different from get_factory
followed by a dynamic cast?
If not, this function can be simplified.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It has the specific type directly, so it will go the the type::parse without the type
or value_type
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this should also be renamed?
core/preconditioner/jacobi.cpp
Outdated
// [[x, y], ...] -> array mode | ||
if (auto& obj = config.get("storage_optimization")) { | ||
// only support value mode | ||
// TODO: more than one precision_reduction -> array mode. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same, array mode should not be supported
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
although it can accept shorter list without knowing the matrix size, I remove it now.
57d3df4
to
0b77935
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like a short discussion about the IC and ILU preconditioner. The rest looks good to me!
@thoasm can you either approve the PR or request changes? |
Co-authored-by: Marcel Koch <[email protected]>
Co-authored-by: Marcel Koch <[email protected]>
I wonder whether the instantiation of preconditioner Ic/Ilu in config will leads the duplicated symbol if user also use the same instantiation in their own code. from https://en.cppreference.com/w/cpp/language/inline
should it be safe? |
Classes only emit symbols for their member functions and static member variables and things like the vtable, but there is no symbol for the class itself. |
Co-authored-by: Marcel Koch <[email protected]> Co-authored-by: Thomas Grützmacher <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well done extending the implementation without considerable changes to our build system or public headers!
I would like to have one more name change. The rest looks good to me!
Quality Gate failedFailed conditions See analysis details on SonarCloud Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
This pr contains the config interface for preconditioner and factorization.
TODO: